/*
 * Created by: vadikv
 * Created: Monday, March 10, 2008
 */

using fit;
using OneDayModel.Services;
using OneDayModel.Tests.Mocks;
using TestUtils;

namespace OneDayModel.Tests.Fits.Fixtures.Scenarios
{
    public class NewUserConfirmationFixture : Fixture
    {
        public string SentMails()
        {
            return MockMailSender.GetSentMails();
        }

        private ConfirmationServices GetConfirmationServices()
        {
            return ((ConfirmationServices) ContextManager.TestContext[typeof (ConfirmationServices).Name]);
        }

        public void ConfirmationArrived(string confirmationId)
        {
            GetConfirmationServices().ConfirmUser(confirmationId.Split('=')[1]);
        }
    }
}